Repetier-Firmware  1.0.0
MotorDriverInterface Class Referenceabstract

#include <Drivers.h>

Inheritance diagram for MotorDriverInterface:
StepperDriver< stepPin, dirPin, enablePin, invertDir, invertEnable > StepperDriverWithEndstop< stepPin, dirPin, enablePin, invertDir, invertEnable, endstopPin, invertEndstop, minEndstop, endstopPullup >

Public Member Functions

virtual void initialize ()=0
 
virtual float getPosition ()=0
 
virtual void setCurrentAs (float newPos)=0
 
virtual void gotoPosition (float newPos)=0
 
virtual void enable ()=0
 
virtual void disable ()=0
 
virtual void home (bool goToCurrent, bool onlyIfNotHomed)=0
 

Detailed Description

For some special printers you need to control extra motors. Possible reasons are

  • Extruder switches
  • Clearing surface
  • Leveling

Repetier-Firmware supports up to 4 extra motors that can be controlled by G201 P<motorId> X<pos> - Go to position X with motor motorId G202 P<motorId> X<setpos> - Mark current position as X G203 P<motorId> - Report current motor position G204 P<motorId> S<0/1> - Enable/disable motor G205 P<motorId> S<0/1> E<0/1> - Home motor, S1 = go back to stored position, E1 = home only if endstop was never met, meaning it was never homed with motor.

These motors are already special and there might be different types, so we can not assume one class fits all needs. So to keep it simple, the firmware defines this general interface which a motor must implement. That way we can handle any type without changing the main code.

Member Function Documentation

◆ disable()

◆ enable()

◆ getPosition()

◆ gotoPosition()

◆ home()

◆ initialize()

◆ setCurrentAs()


The documentation for this class was generated from the following file: